package org.example;

public class Class1 {
    // 班级基本属性
    private String classId;       // 班级编号
    private String className;     // 班级名称
    private String classAddress;  // 班级地址

    // 构造方法
    public Class1(String classId, String className, String classAddress) {
        this.classId = classId;
        this.className = className;
        this.classAddress = classAddress;
    }

    // Getter和Setter方法
    public String getClassId() {
        return classId;
    }

    public void setClassId(String classId) {
        this.classId = classId;
    }

    public String getClassName() {
        return className;
    }

    public void setClassName(String className) {
        this.className = className;
    }

    public String getClassAddress() {
        return classAddress;
    }

    public void setClassAddress(String classAddress) {
        this.classAddress = classAddress;
    }

    // 重写toString方法，方便打印班级信息
    @Override
    public String toString() {
        return "班级{" +
                "编号='" + classId + '\'' +
                ", 名称='" + className + '\'' +
                ", 地址='" + classAddress + '\'' +
                '}';
    }
}
